<template>
	<div class="coma">
		<h2>组件A</h2>
        <p>{{info}}</p>
		<ComB :msg="message" @bindInfo="bindMessage"></ComB>
	</div>
</template>

<script>
import ComB from '@/components/ComB.vue'
export default {
	components: {
		ComB,
	},
    data() {
        return {
            message:'这是父组件数据',
            info:''
        }
    },
    methods:{
        bindMessage(info){
            this.info = info
            console.log('触发自定义事件》》》》',info);
            
        }
    }
}
</script>

<style lang="css" scoped>
.coma{
    width: 500px;
    height: 600px;
    background-color: pink;
}
</style>
